package com.gym.controller;

import com.gym.pojo.Equipmenttype;
import com.gym.service.EquipmenttypeService;
import com.gym.vo.EquimenttypeVo;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RequestMapping("/equipment-provider")
@RestController
public class EquipmenttypeController {

    @Resource
    private EquipmenttypeService equipmenttypeService;

    /**
     * 查询所有分类信息
     * @return
     */
    @RequestMapping("/selAllType")
    public List<EquimenttypeVo> selAllType(){
        return equipmenttypeService.selAllType();
    }

    /**
     * 查询各类健身器材的名称
     * @return
     */
    @GetMapping("/selEquTypeNums")
    public List<EquimenttypeVo> selEquTypeNums(){
        return equipmenttypeService.selEquTypeNums();
    }


}
